Release 10.1A: OpenEdge Data Management:
SQL Development
The READPAST locking hint
The
READPASTlocking hint skips locked rows. This option causes a transaction to skip rows locked by other transactions that would ordinarily appear in the result set, rather than block the transaction waiting for the other transactions to release their locks on these rows. TheREADPASTlock hint applies only to transactions operating atREAD COMMITTEDisolation level and will read only past row-level locks. This only applies to theSELECTstatement.The locking hint clause, such as
READPAST, can only be specified in the mainSELECTstatement, but not in the subquerySELECTstatement in the search condition of theWHEREclause.The
SELECTstatement uses the following syntax:Syntax
The
WITHphrase uses the following syntax:
NOWAIT— Causes theSELECTstatement to skip (read past) the row immediately if a lock cannot be acquired on a row in the selection set because of the lock held by some other transaction. The default behavior is for the transaction to wait until it gets the required lock or until it times out waiting for the lock.WAITtimeout—Overrides the default lock-wait time-out. The time-out value is in seconds and can be given a 0 or any positive number.The
SELECTstatements in Example 8–4 and Example 8–5 illustrate the use of theREADPASTlocking hint.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |